import instance from "./request";

export function listComments(query) {
    return instance.request({
        url: '/system/comments/list',
        method: 'get',
        params: query
    })
}

export function getComments(commentId) {
    return instance.request({
        url: '/system/comments/' + commentId,
        method: 'get'
    })
}

export function addComments(data) {
    return instance.request({
        url: '/system/comments',
        method: 'post',
        data: data
    })
}

export function updateComments(data) {
    return instance.request({
        url: '/system/comments',
        method: 'put',
        data: data
    })
}

export function delComments(commentId) {
    return instance.request({
        url: '/system/comments/' + commentId,
        method: 'delete'
    })
}
